const Layout = () => import("@/layout/index.vue");

export default [
  {
    path: "/login",
    name: "Login",
    component: () => import("@/views/login/index.vue"),
    meta: {
      title: "登录",
      showLink: false,
      rank: 101
    }
  },
  {
    path: "/pharmacists",
    component: Layout,
    meta: {
      title: "药师审核",
      icon: "healthicons:doctor"
    },
    children: [
      {
        path: "",
        name: "Pharmacists",
        component: () => import("@/views/pharmacists/index.vue"),
        meta: {
          title: "药师审核"
        }
      }
    ]
  },
  {
    path: "/jianhuo",
    component: Layout,
    redirect: "/jianhuo/list",
    meta: {
      title: "拣货管理",
      icon: "material-symbols:package-outline"
    },
    children: [
      {
        path: "/jianhuo/list",
        name: "jhList",
        component: () => import("@/views/jianhuo/list.vue"),
        meta: {
          title: "拣货管理"
        }
      }
    ]
  },
  {
    path: "/fenjian",
    component: Layout,
    redirect: "/fenjian/fjList",
    meta: {
      title: "拣货分拣",
      icon: "material-symbols:package-outline"
    },
    children: [
      {
        path: "/fenjian/fjList",
        name: "fjList",
        component: () => import("@/views/fenjian/list.vue"),
        meta: {
          title: "拣货单列表"
        }
      },
      {
        path: "/fenjian/fjCheck",
        name: "fjCheck",
        component: () => import("@/views/fenjian/check.vue"),
        meta: {
          title: "扫码分拣",
          showLink: false
        }
      },
      {
        path: "/fenjian/summary",
        name: "fjSummary",
        component: () => import("@/views/fenjian/summary.vue"),
        meta: {
          title: "拣货汇总单"
        }
      }
      // {
      //   path: "/fenjian/package",
      //   name: "fjPackage",
      //   component: () => import("@/views/fenjian/package.vue"),
      //   meta: {
      //     title: "包裹单"
      //   }
      // }
    ]
  },
  {
    path: "/check",
    component: Layout,
    redirect: "/check/check",
    meta: {
      title: "复核装包",
      icon: "mingcute:package-line"
    },
    children: [
      {
        path: "/check/check",
        name: "checkCheck",
        component: () => import("@/views/check/check.vue"),
        meta: {
          title: "复核"
        }
      }
      // {
      //   path: "/check/paper",
      //   name: "checkPaper",
      //   component: () => import("@/views/check/paper.vue"),
      //   meta: {
      //     title: "面单"
      //   }
      // }
    ]
  },
  {
    path: "/box",
    component: Layout,
    redirect: "/box/list",
    meta: {
      title: "装箱出库",
      icon: "mingcute:package-line"
    },
    children: [
      {
        path: "/box/list",
        name: "boxList",
        component: () => import("@/views/box/list.vue"),
        meta: {
          title: "装箱列表",
          showParent: true
        }
      },
      {
        path: "/box/create",
        name: "boxCreate",
        component: () => import("@/views/box/create.vue"),
        meta: {
          title: "新建装箱单",
          showLink: false
        }
      }
    ]
  },
  {
    path: "/parcel",
    component: Layout,
    redirect: "/parcel/list",
    meta: {
      title: "包裹处理",
      icon: "mingcute:package-line"
    },
    children: [
      {
        path: "/parcel/list",
        name: "parcelList",
        component: () => import("@/views/parcel/list.vue"),
        meta: {
          title: "包裹处理"
        }
      }
    ]
  }
] as Array<RouteConfigsTable>;
